<h1>Editing product</h1>

<% form_for(@product) do |f| %>
  <%= f.error_messages %>
  <table>
      <tr>
          <td><label for="name">Product Name: </label></td>
          <td><%=f.text_field 'name' %></td>
      </tr>
      <tr>
          <td><label for="title">Product Title: </label></td>
          <td><%=f.text_field 'title' %></td>
      </tr>
      <tr>
          <td><label for="description">Description: </label></td>
          <td><%=f.text_area 'description' %></td>
      </tr>
      <tr>
          <td><label for="image_url">Image Url: </label></td>
          <td><%=f.text_field 'image_url' %></td>
      </tr>
      <tr>
          <td><label for="price">Price: </label></td>
          <td><%=f.text_field 'price' %></td>
      </tr>
  </table>  
  <p>
  <%= f.submit "Update" %>
  </p>
<% end %>

<%= link_to 'Show', @product %> |
<%= link_to 'Back', products_path %>
